// extract module
var http = require('http');

// create and run web server
http.createServer(function(request, response) {
	// declare variable
	var date = new Date();
	date.setDate(date.getDate() + 7);
	
	// store cookies
	response.writeHead(200, {
		'Content-Type': 'text/html',
		'Set-Cookie': [
		     'breakfast = toast;Expires = ' + date.toUTCString(), 
		     'dinner = chicken'
		]
	});
	
	// print cookie
	response.end('<h1>' + request.headers.cookie + '</h1>');
}).listen(52273, function() {
	console.log('Server running at http://127.0.0.1:52273');
});

